const crypto = require('crypto');


function md5(str) {
	let obj = crypto.createHash('md5');
	obj.update(str);
	return obj.digest('hex');
}

console.log(md5(md5('123456')));   // 14e1b600b1fd579f47433b88e8d85291
